<!-- src/views/Home.vue -->
<template>
  <div class="home">
    <h1>Welcome to the Home Page!</h1>
    <MyButton type="primary" @click="handleButtonClick">Click Me</MyButton>
  </div>
</template>

<script>
// 禁用 vue/multi-word-component-names 规则
/* eslint-disable vue/multi-word-component-names */

// 引入 MyButton 组件
import MyButton from "../components/MyButton.vue";

export default {
  name: "HomePage", // 使用多词组件名
  components: {
    MyButton, // 注册 MyButton 组件
  },
  methods: {
    handleButtonClick() {
      console.log("Button in Home clicked!");
      alert("Button in Home clicked!");
    },
  },
};
</script>

<style scoped>
.home {
  text-align: center;
  padding: 100px;
}
</style>
